package com.yuwj.chinaa.adapter;

import android.content.Context;

import com.chad.library.adapter.base.BaseQuickAdapter;
import com.chad.library.adapter.base.BaseViewHolder;
import com.yuwj.chinaa.R;
import com.yuwj.chinaa.entity.EntityComputeCodeEarningRecord;

import java.util.List;

/**
 * 算码收益记录adapter
 */
public class ComputeCodeEarningRecordAdapter extends BaseQuickAdapter<EntityComputeCodeEarningRecord, BaseViewHolder> {
    Context context;

    public ComputeCodeEarningRecordAdapter(Context context, List<EntityComputeCodeEarningRecord> datas) {
        super(R.layout.item_compute_code_earning_record, datas);
        this.context = context;
    }

    @Override
    protected void convert(BaseViewHolder holder, final EntityComputeCodeEarningRecord item) {
        holder.setText(R.id.tv_name,item.getName());
        holder.setText(R.id.tv_runtime,item.getRuntime());
        holder.setText(R.id.tv_profit,item.getProfit());
    }

}
